y1=NN_v2(Xtrain);
y1=round(y1);
numberX=size(Xtrain);
zG=[];
for i=1:numberX(1)
    laserG=Xtrain(i,1);
    sonicG=Xtrain(i,2);
%     Measure=Ytrain(i,:);
    r=0.01;
%     noise=sqrt(r)*randn(size(Measure));
%     Mzk=Measure+noise;
%     z1=Mzk(1);
%     z2=Mzk(2);
%     z3=Mzk(3);
    AVE_distance=(laserG+21.4)*0.6+(sonicG+112.6)*0.4;
    if(AVE_distance>=0.5*1000&&AVE_distance<0.8*1000)
        z2=0;
        z1=1;
    elseif(AVE_distance>=0.8*1000)
        z1=1;
        z2=1;
    else
        z1=0;
        z2=0;
    end
    q=0.01;
    zOUT=mul_sensor_nnlmkf(laserG,sonicG,z1,z2,q,r);
    zG=[zG,zOUT];
end
zG=round(zG);
corr_NN=0;
corr_NN_LMKF=0;
zGt=zG';
for i=1:numberX(1)
    if(y1(i,:)==Ytrain(i,:))
        corr_NN=corr_NN+1;
    end
    if(zGt(i,:)==Ytrain(i,:))
        corr_NN_LMKF=corr_NN_LMKF+1;
    end
end
accNN=corr_NN/numberX(1);
accNN_LMKF=corr_NN_LMKF/numberX(1);